package hczc.longcai.com.hccrowdfunding.search;

import android.os.Bundle;
import android.view.MotionEvent;
import android.view.View;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.TextView;

import hczc.longcai.com.hccrowdfunding.R;
import hczc.longcai.com.hccrowdfunding.activity.BaseActivity;

/**
 * 搜索页面
 */
public class SearchActivity extends BaseActivity implements View.OnClickListener, View.OnTouchListener {

    private ImageView back;
    private TextView serach;
    private EditText input;

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_search);

        initViews();
    }

    private void initViews() {
        back = ((ImageView) findViewById(R.id.search_head_back));
        back.setOnClickListener(this);
        back.setOnTouchListener(this);
        serach = ((TextView) findViewById(R.id.serach_head_serach));
        input = ((EditText) findViewById(R.id.serach_head_input));
    }

    @Override
    public void onClick(View view) {
        int index = view.getId();
        switch (index){
            case R.id.search_head_back:
                finish();
                break;
            case R.id.serach_head_input:
                break;
            case R.id.serach_head_serach:

                break;
        }
    }

    @Override
    public boolean onTouch(View view, MotionEvent motionEvent) {
        view.setPressed(true);
        return false;
    }
}
